package com.jyxd.web.data.basic;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.hibernate.annotations.GenericGenerator;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;

/**
 * 床位安排表
 */
@Entity
@Table(name = "table_bed_arrange")
@Data
@TableName("table_bed_arrange")   //mybatis-plus标识哪张表
public class BedArrange extends Model implements Serializable {

    /**
     * 序列
     */
    private static final long serialVersionUID = 1L;

    /**
     * 主键ID
     */
    @Id
    @Column(name = "id", length = 32, nullable = false)
    @GeneratedValue(generator="system-uuid")
    @GenericGenerator(name = "system-uuid", strategy = "uuid.hex")
    private String id;

    /**
     * 床位code
     */
    @Column(name = "bed_code")
    private String bedCode;

    /**
     * 病人主键id
     */
    @Column(name = "patient_id")
    private String patientId;

    /**
     * 监护仪code
     */
    @Column(name = "monitor_code")
    private String monitorCode;

    /**
     * 床位预约标识
     */
    @Column(name = "bed_subscribe")
    private String bedSubscribe;

    /**
     * 绑定时间
     */
    @JsonFormat(locale = "zh", timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @Column(name = "bind_date")
    private Date bindDate;

    /**
     * 绑定人
     */
    @Column(name = "binding_name")
    private String bindingName;
    /**
     * 绑定人
     */
    @Column(name = "tenant_id")
    private String tenantId;



}
